#!/usr/bin/perl
# toan tu so
# +, -, *, /, %, ++
$a = 1;
print ($a+1);print "\n";
# toan tu chuoi
$str = "anh";
print $str."\n";
$str = $str."yeu"."em";
print $str ."\n";

# chop xoa
chop $str;
print $str;
print chop($str), "\n";

# chmop xoa ki tu xuong dong \n
# chmop $str; error ?
$str = $str ."\n";
print $str;
chomp($str);
print $str;

# tach chuoi
print "\n tach chuoi\n";
$_ = "0ne two three";
@list = split;
print $list[0], $list[1], $list[2];

print "\n join\n";
$j=join "?", @list;
print "$j\n";

print "\nsubstr\n";
$str ="perl tutorial";
print substr($str, 0,5);

print "\nlength\n";
print length $str;
